Skip to main content

Shift premium, basic

Award a shift premium for all worked hours between a start and end time (e.g. 2nd shift). A minimum number of hours can be specified along with the days of the week which qualify

Details

Rule Type
Time

Execution
After shift

Parameters

NameDataTypeDefaultValueDescription
Start timetimeThe start time of the shift premium
Stop timetimeThe stop time of the shift premium
Days of weeklistThe days of the week for which the shift premium is available
Rate TablelookupThe rate table to use for awarding pay during this shift premium schedule
Minimum hoursfloat0The minimum number of hours needed before the shift premium is paid out (prevents paying out small overlaps from other shifts)
HourTypelookupThe earnings code to use for the REG portion of any awarded shift premium

Decision Tree

Rule processing begins in the cell R1:Level1 and proceeds right/down. Any IF statement which results in a DONE step terminates the rule immediately.

Line#Level1Level2Level3Comment
1Start
2IF(DAY_OF_WEEK(PayDate) not in Days of week) Is the shift premium available on the current paydate?
3DONE
4SET(defaultrate = LOOKUP(ShiftPremiums, Rate Table, Code, DefaultRate))Lookup the Default Rate in the Rate Table
5SET(rate = BEST_FIT_ITEMS(ShiftPremiums, Code, Rate Table, Rates, FIND(employee, ``), EffectiveDate, ExpireDate, Rate))Find the best fit rate from the rate table for the given employee
6SET(bestrate = GREATER(rate, defaultrate))Compare the the two rates and choose the higher
7IF(bestrate = 0) If the best rate is zero, no diff is awarded
8DONE
9SET(diffhours = COVERAGE(PayDate, Start time, Stop time, Regular))Get the number of regular hours that overlap with the shift premium schedule
10SET(diffhrsot = COVERAGE(PayDate, Start time, Stop time, Overtime))Get the number of overtime hours that overlap with the shift premium schedule
11IF(ADD(diffhours, diffhrsot) < Minimum hours) Don't award if below the minimum coverage hours
12DONE
13SET( = INSERT_PREMIUM(PayDate, HourType, diffhours, diffhrsot, bestrate, Rate Table))Insert the shift premium as a money entry